using System;
using System.Data.Entity.ModelConfiguration;
using System.Data.Common;
using System.Data.Entity;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Elo.Exemplo.EFCodeFirst.Domain.Entities;

namespace Elo.Exemplo.EFCodeFirst.Domain.Mapping
{
	public class Summary_of_Sales_by_QuarterMap : EntityTypeConfiguration<Summary_of_Sales_by_Quarter>
	{
		public Summary_of_Sales_by_QuarterMap()
		{
			// Primary Key
			this.HasKey(t => t.OrderID);

			// Properties
			this.Property(t => t.OrderID)
				.HasDatabaseGeneratedOption(DatabaseGeneratedOption.None);
				
			// Table & Column Mappings
			this.ToTable("Summary of Sales by Quarter");
			this.Property(t => t.ShippedDate).HasColumnName("ShippedDate");
			this.Property(t => t.OrderID).HasColumnName("OrderID");
			this.Property(t => t.Subtotal).HasColumnName("Subtotal");
		}
	}
}

